package com.ssm.service.impl;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Service;

import com.ssm.dao.StockRecordQueryMapper;
import com.ssm.service.TaskService;

@Service
public class TaskServiceImpl implements TaskService {

	Logger log = LoggerFactory.getLogger(TaskServiceImpl.class);
	@Autowired
	public StockRecordQueryMapper stockRecordQueryMapper;
	
	@Override
//	@Scheduled(cron = "0 */1 * * * ?")
	public void dealInstockRecord() {
		log.info("处理入库引入的出库记录");
		stockRecordQueryMapper.dealInstockRecord();
	}

	@Override
	@Scheduled(cron = "0 */1 * * * ?")
	public void dealOutstockRecord() {
//		log.info("处理出库引入的入库记录");
//		stockRecordQueryMapper.dealOutstockRecord();
	}

	@Override
	@Scheduled(cron = "0 */1 * * * ?")
	public void updateFlag() {
//		log.info("更新出入库异常记录状态");
//		stockRecordQueryMapper.updateFlag();
	}

}
